import request from '@/utils/request'

// 查询对货主的评价列表
export function listToConsignor(query) {
  return request({
    url: '/message/toConsignor/list',
    method: 'get',
    params: query
  })
}

// 查询对货主的评价详细
export function getToConsignor(id) {
  return request({
    url: '/message/toConsignor/' + id,
    method: 'get'
  })
}

// 新增对货主的评价
export function addToConsignor(data) {
  return request({
    url: '/message/toConsignor',
    method: 'post',
    data: data
  })
}

// 修改对货主的评价
export function updateToConsignor(data) {
  return request({
    url: '/message/toConsignor',
    method: 'put',
    data: data
  })
}

// 删除对货主的评价
export function delToConsignor(id) {
  return request({
    url: '/message/toConsignor/' + id,
    method: 'delete'
  })
}
